package com.sinocare.report.controller;

import com.sinocare.common.result.Result;
import com.sinocare.common.result.ResultCode;
import com.sinocare.report.service.TestingTimeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@CrossOrigin
@RestController
@RequestMapping("/TestingTime")
@Api(tags = "报表管理接口")
public class TestingTimeController {
    @Resource
    private TestingTimeService testingTimeService;
    @ApiOperation(value = "空腹血糖", notes = "血糖值 ", httpMethod = "GET")
    @RequestMapping(value = "/testingtime", method = RequestMethod.GET)
    public Result findInterpretation() throws Exception {

        List<Integer> list1=testingTimeService.count_of_test();
        System.out.println("结果"+list1);
        return Result.ok(ResultCode.SUCCESS,list1);
    }
}
